package com.itheima.cas;

public class MyTicket extends Thread {
    private static int ticket = 100;
    @Override
    public void run() {
        while(true){
            if(ticket==0){
                break;
            }else{
                ticket--;
                System.out.println("还剩下"+ticket+"张票");
            }
        }
    }
}
